package cn.hairui.blog.constant;

/**
 * 常量定义类
 */
public class PubConstant {

    /**
     * 用户类型 admin-系统管理员
     */
    public static final String USER_TYPE_SUPER_ADMIN = "admin";

    /** 默认站点信息编号 */
    public static int MY_INFO_ID = 1;
    /** 全局用户登录session名称 */
    public static final String GLOBAL_SESSION_NAME = "userinfo";

    /** 默认新建用户头像名称 */
    public static final String DEF_USER_PHOTO_NAME = "user_default.jpg";

    /** 密码错误最大次数*/
    public static final int MAX_ERROR_ACCOUNT_TIMES = 3;

    /** 邮箱验证码最大有效时间（分钟）*/
    public static final int MAIL_CODE_EFFECT_MINUTES = 5;

    /**本机登录的ip地址*/
    public static final String LOCAL_IP_ADDRESS_STR = "0:0:0:0:0:0:0:1";
    public static final String LOCAL_IP_ADDRESS_STR_FORMAT = "127.0.0.1";

    /**系统认定为同一次访问最大时间（单位：小时）*/
    public static final int VISITED_NEW_HOURS = 3;
    /** 文章类型 0-原创 1-转载 */
    public static final String REPRINT_TYPE_0 = "0";
    public static final String REPRINT_TYPE_1 = "1";

    /** 链接状态 留言状态 审核状态 0-待审核 1-通过 2-否决 */
    public static final String APPROVE_STS_0 = "0";
    public static final String APPROVE_STS_1 = "1";
    public static final String APPROVE_STS_2 = "2";

    /** 是否标志 Y-是 N-否 */
    public static final String YES_NO_Y = "Y";
    public static final String YES_NO_N = "N";

    /** 用户状态 0-正常 1-锁定 */
    public static final String USER_STATUS_0 = "0";
    public static final String USER_STATUS_1 = "1";

    /** 博客类型 1-好友博客 2-大佬博客 3-学习网站 */
    public static final String BOLG_TYPE_1 = "1";
    public static final String BOLG_TYPE_2 = "2";
    public static final String BOLG_TYPE_3 = "3";

    /** 相册文件夹 album */
    public static final String ALBUM_DIR = "album/";

    /** 相册封面文件夹名称 cover */
    public static final String COVERS_DIR = "cover/";

    /** 相册照片文件夹名称 images */
    public static final String IMAGES_DIR = "images/";

    /** 文章中上传的文件相对路径 artical */
    public static final String ARTICAL_DIR = "artical/";

    /** 友链网站icon存放相对路径 link */
    public static final String LINK_DIR = "link/";

    /** 首页展示分类数量 */
    public static final int INDEX_TOP_TYPE_COUNT = 6;

    /** 首页展示标签数量 */
    public static final int INDEX_TOP_TAG_COUNT = 15;

    /** 首页展示最新推荐 */
    public static final int INDEX_TOP_NEWARTICAL_COUNT = 6;

    /** 首页展示文章数量 */
    public static final int INDEX_PAGE_SIZE = 10;

    /** 归档中每年最多展示文章数量 */
    public static final int ARCHIVES_SHOW_COUNT = 6;

    public static String success = "success";
    public static String flag = "flag";
    public static String failed = "failed";
    public static String locked = "locked";
    public static String exsit = "exsit";
    public static final String ON = "on";
    public static final String OFF = "off";

    public static final String CHARSET_UTF8 = "UTF-8";
}
